package com.hxkj.config;

import com.hxkj.service.webSocket.WebSocketService;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

@Component
public class MessageReceiver {

    @Resource
    WebSocketService webSocketService;
    /**接收消息的方法*/
    public void receiveMessage(String message){
        System.out.println("enter");
        System.out.println(message);
        webSocketService.sendMsg(message);
    }

}

